<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <div>
        <span class="s"></span>
    </div>
    <input type="text" value="输入内容">
    <script>
        // 1.获取设置元素内容 html()
        console.log($("div").html());
        // 2.获取元素文本内容
        console.log($("div").text());
        $("div").text();
        // 3.设置表单值 val()
        console.log($("input").val("123"));
        $("input").val("123");
    </script>
</body>

</html>